Vue.component('two-nav',
  {
    template: "<div>"+
    "<div class='bar'>\
      <p class='borderRight' :class='{default:currenturl===list[0]}' @click='toPage(list[0])'>收入</p>\
      <p class='borderRight' :class='{default:currenturl===list[1]}' @click='toPage(list[1])'>收币</p>\
      <p class='borderRight' :class='{default:currenturl===list[2]}' @click='toPage(list[2])'>返奖</p>\
      <p @click='toPage(list[3])' :class='{default:currenturl === list[3]}'>出票</p>\
      <p @click='toPage(list[4])' :class='{default:currenturl === list[4]}'>榜单</p>\
      <p @click='toPage(list[5])' :class='{default:currenturl === list[5]}'>活动</p>\
    </div>\
    </div>",
    data: function() {
      return {
        list:['incomeDetail','coinStoreDetail','rewardStoreDetail','lotteryStoreDetail','rankingList','activity']
      }
    },
    props:{
      currenturl:{
        defalut:''
      },
      storename:{
        defalut:''
      },


    },

    computed:{},
    mounted:function(){},
    methods: {
      toPage:function(url){
        if(url !== this.currenturl){
          this.$parent.toOtherPage(url);
          console.log(4)
        }else{
          console.log('是当前页面')
        }



      }
    }
  })